Release 10.1A: OpenEdge Deployment:
Managing 4GL Applications


Terminal capabilities entries

The terminal capabilities section of a terminal entry contains fields that tell OpenEdge features of the terminal being used. These entries are indented from the name line to distinguish them from the terminal name.

Terminal capabilities entries control visual attributes of the terminal: how big the terminal screen is, how to move to any point on the screen, how to refresh the screen, how to enter/exit special display modes (reverse, blinking, underline), etc. They also control specific terminal functions to set up and clean up the terminal properly, so as not to leave a terminal in an unexpected state (which might leave the terminal unusable).

These entries are the core sequences that OpenEdge uses to communicate with the terminal. Changing them can cause very unpredictable results and might even cause OpenEdge to put the terminal in an unusable state. The entries can be changed, but exercise great care in doing so.

Terminal capability entries consist of:

For example:

:ct:\
:cm=\E[%i%d;%dH:\
:co#80:\
:li#24:\
:G1=k:\ 

Functional listing of terminal capabilities

These are the cursor terminal capabilities that OpenEdge supports:

bc, CF, CN, cm, kd, kl, kr, ku, ke, ks

These are the color/video terminal capabilities that OpenEdge supports:

BB, BR, ct, HS, HR, se, so, ue, us

These are the graphics character terminal capabilities that OpenEdge supports:

G1, G2, G3, G4, GH, GV, GE, GS

Note: Do not use a padding constant with any of the above graphic strings.

These are miscellaneous terminal capabilities that OpenEdge supports:

co, li, CA, ce, cl, is, Se, Si, te, ti, pc, xi

These are the key translation capabilities that OpenEdge supports:

k0, k1, k2, k3, k4, k5, k6, k7, k8, k9, k0, k. (period), k, (comma), k- (hyphen)

These are the scroll region capabilities that OpenEdge supports:

al, sf, sr, dl, cs

Notes: The ce, cl, and cm capabilities are required for OpenEdge to start up.

Vermont Views supports all the capabilities listed here, except ce, te, and ti, and the key translation capabilities.

Table 4–8 describes the mnemonics that OpenEdge supports.

Table 4–8: Alphabetical listing of capability mnemonics
Mnemonic
Data type
Description
al
STRING 
Add line.
bc
STRING 
Backspace character.
BB
STRING 
Enter COLOR 4 mode (usually blink mode).
BR
STRING 
Exit COLOR 4 mode (usually blink mode).
CA
BOOLEAN 
Terminal clears screen with current attribute. If you do not specify and this capability is available, full-screen clears with attributes other than NORMAL will be slow.
ce
STRING 
Clear to end of line.
CF
STRING 
Cursor off.
cl
STRING 
Clear screen. This improves speed. On some terminals, you must define cl as home cursor followed by clear to end of screen.
cm
STRING 
Cursor motion.
CN
STRING 
Cursor on.
co
INTEGER 
Columns on screen (usually 80).
cs
STRING 
Change scroll region. Uses cm syntax.
ct
BOOLEAN 
Terminal supports color.
dl
STRING 
Delete line.
G1
STRING 
Single-line upper-right corner character.
G2
STRING 
Single-line upper-left corner character.
G3
STRING 
Single-line lower-left corner character.
G4
STRING 
Single-line lower-right corner character.
GE
STRING 
Graphics end. Sent when finished drawing box or underline.
GH
STRING 
Single-line horizontal character.
GS
STRING 
Graphics start. Sent to begin drawing box or underline.
GV
STRING 
Vertical-line graphic character.
HR
STRING 
Exit COLOR 3 mode (usually highlight mode).
HS
STRING 
Enter COLOR 3 mode (usually highlight mode). This is usually set to high intensity, if available.
is
STRING 
Terminal initialization string. Sent when OpenEdge starts.
k0-9
k.
k,
k-
STRING 
Define the codes sent by the numeric keypad keys if these are different from the codes sent by the standard 0-9, period, comma, and hyphen keys. These are only used by OpenEdge.
kd
STRING 
Down arrow.
ke
STRING 
Exit keypad mode.
kl
STRING 
Left arrow.
kr
STRING 
Right arrow.
ks
STRING 
Set keypad mode.
ku
STRING 
Up arrow.
li
INTEGER 
Lines on screen (usually 24).
pc
CHARACTER 
Pad character (defaults to null).
Se
STRING 
String to send when OpenEdge terminates (after te).
se
STRING 
Exits COLOR 2 mode, or MESSAGE color (usually reverse video).
sf
STRING
Scroll forward. You can use this on terminals that have scrolling regions (for example, terminals with cs and sr defined).
Si
STRING
String to send when OpenEdge starts (after is).
so
STRING
Enter COLOR 2 mode, or MESSAGE color (usually reverse video). OpenEdge uses this attribute by default for the two-line message area at the bottom of the screen. It is also the default for the PROMPT-FOR color of selectable widgets (that is, buttons, sliders, toggle-boxes, etc.). If not set and the PROMPT-FOR color of a widget is not explicitly set in the 4GL, a widget might not be visible.
sr
STRING
Scroll reverse.
te
STRING
Cursor movement string to send when OpenEdge terminates.
ti
STRING
Cursor movement string to send when OpenEdge starts.
ue
STRING
Exit COLOR 1 mode, or INPUT color.
us
STRING
Enter COLOR 1 mode, or INPUT color (usually the underline attribute). OpenEdge uses COLOR 1 as the default PROMPT-FOR color for fill-ins and editors. If COLOR 1 is not defined by the us and ue capabilities, and the PROMPT-FOR color for fill-ins and editor widgets is not explicitly set in the 4GL, these widgets might not be visible, and there might be no indication they are enabled.
ws
BOOLEAN
Uses the device /dev /tty for the current port to determine the number of columns and rows for the terminal. Meaningful primarily for emulated terminals in a windowing system (that is, xterm). If successful, overrides co and li; otherwise, defaults to co and li. OpenEdge will not automatically resize if the size of the terminal changes after initialization.
xi
BOOLEAN
Terminal will not automatically do a hardware scroll when the last position (last row and last column) on the screen is written to. Specify whether available, otherwise OpenEdge will not write to the last position in order to avoid the automatic scrolling.

There are four types of terminal capability fields: BOOLEAN, NUMERIC, CHARACTER, and STRING. Table 4–9 summarizes the four data types and the operators used in conjunction with each. Boolean fields are specified by a mnemonic abbreviation only. The mnemonic indicates that the feature is present and its absence indicates that the feature is not present. All other capabilities take a value. The value can be a string, a character, or a numeric value.

Table 4–9: Data types and operators 
Data type
Operator
BOOLEAN 
none
NUMERIC 
# and value
CHARACTER 
= and character
STRING 
= and string

The following code fragment from the terminal entry for the Wyse 370 terminal shows how to specify BOOLEAN, NUMERIC, CHARACTER, and STRING capabilities:

:ct:\
:cm=\E[%i%d;%dH:\
:co#80:\
:li#24:\
:G1=k:\ 

In this example, the mnemonic ct is a Boolean switch that indicates that the terminal supports color. The mnemonic cm specifies cursor motion and takes a string. The assignment operator for string values is an equals sign (=). The mnemonics co and li specify the number of columns and lines on the display and each takes an integer. The assignment operator for integer values is a pound sign (#). The mnemonic G1 specifies the upper-right corner line-graphic character and takes a character. The assignment operator for character values is an equals sign (=).


Copyright © 2005 Progress Software Corporation
www.progress.com
Voice: (781) 280-4000
Fax: (781) 280-4095